import { axios as request } from '@/utils/request'

// 根据表格Id查询
export function getListByTableId(tableId) {
  return request({
    url: `/form/layout/query/${tableId}`,
    method: 'get'
  })
}

// 主键查询
export function getInfoById(id) {
  return request({
    url: `/form/layout/get/${id}`,
    method: 'get'
  })
}

// 新增数据
export function create(data) {
  return request({
    url: `/form/layout/create`,
    method: 'post',
    data
  })
}

// 修改数据
export function update(data) {
  return request({
    url: `/form/layout/update`,
    method: 'put',
    data
  })
}

// 逻辑删除
export function remove(ids) {
  return request({
    url: `/form/layout/delete/${ids}`,
    method: 'delete'
  })
}
